package com.agent.platform.repository;

import com.agent.platform.entity.Agent;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Optional;

/**
 * Agent数据访问接口
 */
@Repository
public interface AgentRepository extends JpaRepository<Agent, String> {

    Optional<Agent> findByAgentId(String agentId);

    List<Agent> findByStatus(String status);

    boolean existsByAgentId(String agentId);
}
